package com.trkj.pojo;

import java.io.Serializable;
import javax.persistence.*;

import com.alibaba.fastjson.annotation.JSONField;

import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.List;


/**
 * The persistent class for the RECRUITPLAN database table.
 * 
 */
@Entity
@NamedQuery(name="Recruitplan.findAll", query="SELECT r FROM Recruitplan r")
public class Recruitplan implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@SequenceGenerator(name="RECRUITPLAN_RECPLANID_GENERATOR", sequenceName="HR")
	@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="RECRUITPLAN_RECPLANID_GENERATOR")
	@Column(name="RECPLAN_ID")
	private long recplanId;
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	@Column(name="RECPLAN_ACENDDATE")
	private Timestamp recplanAcenddate;
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	@Column(name="RECPLAN_ACTUALDATE")
	private Timestamp recplanActualdate;

	@Column(name="RECPLAN_ACTUALMONEY")
	private BigDecimal recplanActualmoney;

	@Column(name="RECPLAN_DESCRIBE")
	private String recplanDescribe;

	@Column(name="RECPLAN_ESTIMATE")
	private BigDecimal recplanEstimate;

	@Column(name="RECPLAN_MODE")
	private String recplanMode;

	@Column(name="RECPLAN_MODESCRIBE")
	private String recplanModescribe;
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	@Column(name="RECPLAN_PENDDATE")
	private Timestamp recplanPenddate;

	@Column(name="RECPLAN_PERSON")
	private String recplanPerson;

	@Column(name="RECPLAN_PLACE")
	private String recplanPlace;
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	@Column(name="RECPLAN_PSTARTDATE")
	private Timestamp recplanPstartdate;

	//bi-directional many-to-one association to Jobseekersregister
	@OneToMany(mappedBy="recruitplan")
	@JSONField(serialize=false)
	private List<Jobseekersregister> jobseekersregisters;

	//bi-directional many-to-one association to Organization
	@ManyToOne
	@JoinColumn(name="ORGANI_ID")
	private Organization organization;

	//bi-directional many-to-one association to RecruitAdministration
	@OneToMany(mappedBy="recruitplan")
	@JSONField(serialize=false)
	private List<RecruitAdministration> recruitAdministrations;

	public Recruitplan() {
	}

	public long getRecplanId() {
		return this.recplanId;
	}

	public void setRecplanId(long recplanId) {
		this.recplanId = recplanId;
	}

	public Timestamp getRecplanAcenddate() {
		return this.recplanAcenddate;
	}

	public void setRecplanAcenddate(Timestamp recplanAcenddate) {
		this.recplanAcenddate = recplanAcenddate;
	}

	public Timestamp getRecplanActualdate() {
		return this.recplanActualdate;
	}

	public void setRecplanActualdate(Timestamp recplanActualdate) {
		this.recplanActualdate = recplanActualdate;
	}

	public BigDecimal getRecplanActualmoney() {
		return this.recplanActualmoney;
	}

	public void setRecplanActualmoney(BigDecimal recplanActualmoney) {
		this.recplanActualmoney = recplanActualmoney;
	}

	public String getRecplanDescribe() {
		return this.recplanDescribe;
	}

	public void setRecplanDescribe(String recplanDescribe) {
		this.recplanDescribe = recplanDescribe;
	}

	public BigDecimal getRecplanEstimate() {
		return this.recplanEstimate;
	}

	public void setRecplanEstimate(BigDecimal recplanEstimate) {
		this.recplanEstimate = recplanEstimate;
	}

	public String getRecplanMode() {
		return this.recplanMode;
	}

	public void setRecplanMode(String recplanMode) {
		this.recplanMode = recplanMode;
	}

	public String getRecplanModescribe() {
		return this.recplanModescribe;
	}

	public void setRecplanModescribe(String recplanModescribe) {
		this.recplanModescribe = recplanModescribe;
	}

	public Timestamp getRecplanPenddate() {
		return this.recplanPenddate;
	}

	public void setRecplanPenddate(Timestamp recplanPenddate) {
		this.recplanPenddate = recplanPenddate;
	}

	public String getRecplanPerson() {
		return this.recplanPerson;
	}

	public void setRecplanPerson(String recplanPerson) {
		this.recplanPerson = recplanPerson;
	}

	public String getRecplanPlace() {
		return this.recplanPlace;
	}

	public void setRecplanPlace(String recplanPlace) {
		this.recplanPlace = recplanPlace;
	}

	public Timestamp getRecplanPstartdate() {
		return this.recplanPstartdate;
	}

	public void setRecplanPstartdate(Timestamp recplanPstartdate) {
		this.recplanPstartdate = recplanPstartdate;
	}

	public List<Jobseekersregister> getJobseekersregisters() {
		return this.jobseekersregisters;
	}

	public void setJobseekersregisters(List<Jobseekersregister> jobseekersregisters) {
		this.jobseekersregisters = jobseekersregisters;
	}

	public Jobseekersregister addJobseekersregister(Jobseekersregister jobseekersregister) {
		getJobseekersregisters().add(jobseekersregister);
		jobseekersregister.setRecruitplan(this);

		return jobseekersregister;
	}

	public Jobseekersregister removeJobseekersregister(Jobseekersregister jobseekersregister) {
		getJobseekersregisters().remove(jobseekersregister);
		jobseekersregister.setRecruitplan(null);

		return jobseekersregister;
	}

	public Organization getOrganization() {
		return this.organization;
	}

	public void setOrganization(Organization organization) {
		this.organization = organization;
	}

	public List<RecruitAdministration> getRecruitAdministrations() {
		return this.recruitAdministrations;
	}

	public void setRecruitAdministrations(List<RecruitAdministration> recruitAdministrations) {
		this.recruitAdministrations = recruitAdministrations;
	}

	public RecruitAdministration addRecruitAdministration(RecruitAdministration recruitAdministration) {
		getRecruitAdministrations().add(recruitAdministration);
		recruitAdministration.setRecruitplan(this);

		return recruitAdministration;
	}

	public RecruitAdministration removeRecruitAdministration(RecruitAdministration recruitAdministration) {
		getRecruitAdministrations().remove(recruitAdministration);
		recruitAdministration.setRecruitplan(null);

		return recruitAdministration;
	}

}